abstract class Shape
{
    abstract getArea():number;
}

class Square extends Shape{
    constructor(public size:number)
    {
        super();
    }

    getArea()
    {
        return this.size**2;
    }
}

class Rectangle extends Shape{

    constructor(public w:number,public h:number)
    {
        super();
    }

    getArea()
    {
        return this.w*this.h;
    }
}

class Circle extends Shape{
    constructor(public radius:number)
    {
        super()
    }

    getArea()
    {
        return Math.PI*this.radius**2;
    }
}

const shape:Shape = new Circle(10);
console.time("begin at");
var ret = shape.getArea();
// setTimeout(function(){
//     console.timeEnd("begin at");
//     console.log("end");
// },2000);
// var who = prompt("who are you:");

for (var i = 0; i < 10000; i++)
{
    console.log("%c i:","color:darkred",i);
}
console.timeEnd("begin at");
console.log("area:",ret);
console.log("%cHello","color:darkblue");